using System;
using System.Web;
using ExtremeSwank.Authentication.OpenID;
using System.Security.Cryptography;

public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
    }
    protected void Page_PreRender(object sender, EventArgs e)
    {
        OpenIDUser oiu = ((OpenIDMasterPage)Master).OpenIDUser;
        string prefix = "openid.sreg.";
        if (User.Identity != null)
        {
            ASPNETName.Text = User.Identity.Name;
        }

        if (oiu != null)
        {
            ActualID.Text = oiu.BaseIdentity;
            Nickname.Text = oiu.GetValue(prefix + "nickname");
            Email.Text = oiu.GetValue(prefix + "email");
            DoB.Text = oiu.GetValue(prefix + "dob");
            Gender.Text = oiu.GetValue(prefix + "gender");
            FullName.Text = oiu.GetValue(prefix + "fullname");
        }
        else
        {
            PersonalPanel.Visible = false;
        }
    }
}
